home *** CD-ROM | disk | FTP | other *** search
-
- /*
- * This file was generated by the SOM Compiler.
- * FileName: Orbit:SampleCode:ScriptRunner:Source:PaletteExt.xh.
- * Generated using:
- * SOM Precompiler somipc: 2.18
- * SOM Emitter emitxh.dll: 2.33
- */
-
- #ifndef SOM_Module_Samples_defined
- #define SOM_Module_Samples_defined 1
- #include <som.xh>
-
- /*
- * Start of user-defined types:
- */
- class SOMClass;
- class SOMObject;
- class ODFrame;
- class ODFacet;
- class ODObject;
- class ODExtension;
- class ODRefCntObject;
- class ODPart;
- class SampleCode_ScriptRunner;
- #define kPaletteExtension "Apple Computer:Extension:ScriptPalette"
-
- /*
- * End of user-defined types.
- */
- #endif /* SOM_Module_Samples_defined */
-
- #ifndef SOM_Samples_PaletteExt_xh
- #define SOM_Samples_PaletteExt_xh
-
- class Samples_PaletteExt;
-
- #define Samples_PaletteExt_MajorVersion 1
- #define Samples_PaletteExt_MinorVersion 0
-
- /*
- * Passthru lines: File: "C.xh", "before"
- */
- class SampleCode_ScriptRunner;
-
- /* C++ SOM defs */
- #include <somcls.xh>
- #include <somcm.xh>
-
- /* C++ parent defs */
- #ifndef SOM_ODExtension_xh
- #include <Extensn.xh>
- #endif
-
- #ifndef Samples_PaletteExt_API
- #define Samples_PaletteExt_API
- /*
- * -- The Class API
- */
-
- /*
- * Start of user-defined types:
- */
-
- /*
- * End of user-defined types.
- */
-
- #ifdef OLDIBMSOMAPISUPPORT
- #define Samples_PaletteExtCClassData Samples_PaletteExtClassData
- #define Samples_PaletteExtNewClass(major,minor) somNewVersionedClassReference(Samples_PaletteExt,major,minor)
- #endif
-
- /* define xxxMetaClass macro to facilitate (cls ## MetaClass) */
- #define Samples_PaletteExtMetaClass SOMClass
-
-
- /* The API to the Samples_PaletteExt class object, and the methods it introduces. */
- SOMEXTERN struct Samples_PaletteExtClassDataStructure {
- #ifdef OLDIBMSOMAPISUPPORT
- SOMClass *classObject; /* always zero, use somNewClassReference instead */
- #else
- long zero;
- #endif
- somStaticClassInfo *sci;
- somDToken instanceDataToken;
- long reserved [3];
- somMToken Show;
- somMToken Hide;
- somMToken IsPaletteVisible;
- somMToken Move;
- somMToken GetLocation;
- somMToken SetClient;
- } SOMDLINK Samples_PaletteExtClassData;
-
- #if !defined(Samples_PaletteExt_Class_Source) && !defined(SOM_Module_paletteext_Source)
- #if PRAGMA_IMPORT_SUPPORTED
- #pragma import list Samples_PaletteExtClassData
- #endif
- #endif
-
-
- /*
- * -- Typedefs and inline method declarations for left path inherited methods
- * -- are omitted because this compilation had -museinheritedmethods in effect
- */
-
-
- /*
- * -- Typedefs for Samples_PaletteExt Method Procedures
- */
- SOMEXTERN {
- typedef void (* SOMLINK somTD_Samples_PaletteExt_Show)(Samples_PaletteExt *somSelf, Environment *ev);
- typedef void (* SOMLINK somTD_Samples_PaletteExt_Hide)(Samples_PaletteExt *somSelf, Environment *ev);
- typedef ODBoolean (* SOMLINK somTD_Samples_PaletteExt_IsPaletteVisible)(Samples_PaletteExt *somSelf, Environment *ev);
- typedef ODBoolean (* SOMLINK somTD_Samples_PaletteExt_Move)(Samples_PaletteExt *somSelf, Environment *ev,
- ODPoint* topleft);
- typedef ODPoint* (* SOMLINK somTD_Samples_PaletteExt_GetLocation)(Samples_PaletteExt *somSelf, Environment *ev);
- typedef void (* SOMLINK somTD_Samples_PaletteExt_SetClient)(Samples_PaletteExt *somSelf, Environment *ev,
- ODPart* client);
- }
-
- #endif /* Samples_PaletteExt_API */
-
-
- /*
- * -- This emitter treats Method Tokens as Thunks by default.
- * -- Use the sc modifier "nothunks" to change this default
- */
- #undef somresolve_
- #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
-
- /*
- * -- The C++ Wrapper Class for Samples_PaletteExt
- */
- class Samples_PaletteExt : public ODExtension
- {
- public:
-
- // Samples_PaletteExt::new registers use of the class object, and then uses somNew
- // to allocate memory and load the object method table pointer.
- void *operator new(size_t size)
- {
- SOM_IgnoreWarning(size);
- // Allocate memory using the default allocator for Samples_PaletteExt, and
- // clear mem & set method table pointer, call basic initialization
- #ifdef SOMCHKNULL
- void * __somResult = (void *)
- somNewObject(Samples_PaletteExt);
- SOMCHKNULL(__somResult);
- return __somResult;
- #else
- return (void*) somNewObject(Samples_PaletteExt);
- #endif
- }
-
- // Samples_PaletteExt::delete uses the default deallocator for the object's class.
- void operator delete(void * obj)
- {
- if (obj) {
- SOM_Resolve(obj,SOMObject,somFree)
- ( (SOMObject*) obj );
- }
- }
-
- /* method: Show */
- void Show(Environment *ev)
- {
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,Show)
- (this,ev);
- #ifdef SOMCHKEXCEPT
- SOMCHKEXCEPT;
- #endif
- }
-
- /* method: Hide */
- void Hide(Environment *ev)
- {
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,Hide)
- (this,ev);
- #ifdef SOMCHKEXCEPT
- SOMCHKEXCEPT;
- #endif
- }
-
- /* method: IsPaletteVisible */
- ODBoolean IsPaletteVisible(Environment *ev)
- {
- #ifdef SOMCHKEXCEPT
- ODBoolean __somResult =
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,IsPaletteVisible)
- (this,ev);
- SOMCHKEXCEPT;
- return __somResult;
- #else
- return SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,IsPaletteVisible)
- (this,ev);
- #endif
- }
-
- /* method: Move */
- ODBoolean Move(Environment *ev,
- ODPoint* topleft)
- {
- #ifdef SOMCHKEXCEPT
- ODBoolean __somResult =
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,Move)
- (this,ev,topleft);
- SOMCHKEXCEPT;
- return __somResult;
- #else
- return SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,Move)
- (this,ev,topleft);
- #endif
- }
-
- /* method: GetLocation */
- ODPoint* GetLocation(Environment *ev)
- {
- #ifdef SOMCHKEXCEPT
- ODPoint* __somResult =
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,GetLocation)
- (this,ev);
- SOMCHKEXCEPT;
- return __somResult;
- #else
- return SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,GetLocation)
- (this,ev);
- #endif
- }
-
- /* method: SetClient */
- void SetClient(Environment *ev,
- ODPart* client)
- {
- SOM_ResolveD(this,Samples_PaletteExt,Samples_PaletteExt,SetClient)
- (this,ev,client);
- #ifdef SOMCHKEXCEPT
- SOMCHKEXCEPT;
- #endif
- }
-
- }; /* Samples_PaletteExt */
-
-
-
- #endif /* SOM_Samples_PaletteExt_xh */
-